package com.wx.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.wx.dao.WxMassSendResultMapper;
import com.wx.entity.WxMassSendResult;
import com.wx.entity.WxMassSendResultExample;
import com.wx.service.WxMassSendResultService;
import com.zyht.common.BaseDao;
import com.zyht.common.BaseServiceImpl;

@Service("wxMassSendResultService")
public class WxMassSendResultServiceImpl extends BaseServiceImpl<WxMassSendResult, WxMassSendResultExample> implements
		WxMassSendResultService {
	
	@Resource
	private WxMassSendResultMapper mapper;
	
	@Override
	public int addOne(WxMassSendResult entity){
		return  this.mapper.insert(entity);
	}

	@Override
	public List<WxMassSendResult> list(WxMassSendResultExample example){

		return this.mapper.selectByExample(example);
	}

	@Override
	public WxMassSendResult findOneById(Integer id){
		return this.mapper.selectByPrimaryKey(id);
	}

	@Override
	public int count(WxMassSendResultExample example){
		return this.mapper.countByExample(example); 
	}

	@Override
	public int update(WxMassSendResult record,WxMassSendResultExample example){
		return this.mapper.updateByExampleSelective(record,example);
	}

	@Override
	public int updateById(WxMassSendResult record){
		return this.mapper.updateByPrimaryKeySelective(record);
	}

	@Override
	public int deleteById(Integer id){
		return this.mapper.deleteByPrimaryKey(id);
	}

	@Override
	public int deleteByExample(WxMassSendResultExample example){
		return this.mapper.deleteByExample(example);
	}

	@Override
	public BaseDao<WxMassSendResult, WxMassSendResultExample> dao(){
		return mapper; 
	}

}
